import tensorflow as tf

w = tf.Variable(initial_value=1, name='w')
w2  = tf.get_variable(name='w', shape=(1,), dtype=tf.float32)